package cn.edu.sgu.www.mhxysy.entity.trade;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.io.Serializable;
import java.time.LocalDate;

/**
 * 交易记录
 * @author 沐雨橙风ιε
 * @version 1.0
 */
@Data
@ApiModel
@TableName("trade_record")
public class TradeRecord implements Serializable {
    private static final long serialVersionUID = 18L;

    @TableId(value = "id", type = IdType.AUTO)
    @ApiModelProperty(value = "ID")
    private Integer id;

    /**
     * 交易价格
     */
    @ApiModelProperty(value = "交易价格")
    private Integer price;

    /**
     * 角色ID
     */
    @ApiModelProperty(value = "角色ID")
    private String roleId;

    /**
     * 数据编号
     */
    @ApiModelProperty(value = "数据编号")
    private String dataId;

    /**
     * 数据表名
     */
    @ApiModelProperty(value = "数据表名")
    private String tableName;

    /**
     * 交易类型 出售/购买
     */
    @ApiModelProperty(value = "交易类型")
    private Integer tradeType;

    /**
     * 是否跨服
     */
    @ApiModelProperty(value = "是否跨服")
    private Integer crossSever;

    /**
     * 是否指定
     */
    @ApiModelProperty(value = "是否指定")
    private Integer designated;

    /**
     * 交易时间
     */
    @ApiModelProperty(value = "交易时间")
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    private LocalDate tradeTime;
}